package com.leoblog.test.service;

import com.leoblog.action.TestAction;
import com.leoblog.dao.impl.TestDao;
import com.leoblog.domain.Test;
import com.leoblog.service.impl.TestServiceImpl;
import com.leoblog.test.base.AbstractUTestBaseSpringServiceActionTestCase;

public class UTestBaseService extends AbstractUTestBaseSpringServiceActionTestCase {
	
	private TestAction action;
	
	private TestServiceImpl service;	
	
	public void setAction(TestAction action) {
		this.action = action;
	}

	public void setService(TestServiceImpl service) {
		this.service = service;
	}

	public void testDomainFieldSet()
	{
		
		assertEquals("Service get domain through action incorrect", 
				Test.class, action.getService().getDomain().getClass());
	}
	
	public void testDaoFieldSet()
	{
		
		assertEquals("Service get domain through action incorrect", 
				TestDao.class, service.getDao().getClass());
	}
}
